﻿<%@ Page Title="Relatório" Language="C#" MasterPageFile="~/paginas/MasterPage.master" AutoEventWireup="true" CodeFile="RelatorioDoc.aspx.cs" Inherits="paginas_RelatorioDoc"  %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <p>
        Relatório Cadastro de Usuários</p>
    <p>
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
            BackColor="White" BorderColor="#E7E7FF" BorderStyle="None" BorderWidth="1px" 
            CellPadding="3" DataKeyNames="usuario" DataSourceID="SqlDataSource1" 
            EmptyDataText="There are no data records to display." 
            GridLines="Horizontal" Height="100px" Width="200px">
            <RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
            <Columns>
                <asp:BoundField DataField="idPessoa" HeaderText="Código" 
                    SortExpression="idPessoa" />
                <asp:BoundField DataField="usuario" HeaderText="Usuário" ReadOnly="True" 
                    SortExpression="usuario" />
                <asp:BoundField DataField="perfil" HeaderText="Perfil" 
                    SortExpression="perfil" />
            </Columns>
            <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
            <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
            <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" />
            <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" />
            <AlternatingRowStyle BackColor="#F7F7F7" />
        </asp:GridView>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
            ConnectionString="<%$ ConnectionStrings:DefaultConnectionString %>" 
            DeleteCommand="DELETE FROM [usuarios] WHERE [usuario] = @usuario" 
            InsertCommand="INSERT INTO [usuarios] ([idPessoa], [usuario], [senha], [perfil]) VALUES (@idPessoa, @usuario, @senha, @perfil)" 
            ProviderName="<%$ ConnectionStrings:DefaultConnectionString.ProviderName %>" 
            SelectCommand="SELECT [idPessoa], [usuario], [senha], [perfil] FROM [usuarios]" 
            UpdateCommand="UPDATE [usuarios] SET [idPessoa] = @idPessoa, [senha] = @senha, [perfil] = @perfil WHERE [usuario] = @usuario">
            <DeleteParameters>
                <asp:Parameter Name="usuario" Type="String" />
            </DeleteParameters>
            <InsertParameters>
                <asp:Parameter Name="idPessoa" Type="Int32" />
                <asp:Parameter Name="usuario" Type="String" />
                <asp:Parameter Name="senha" Type="String" />
                <asp:Parameter Name="perfil" Type="String" />
            </InsertParameters>
            <UpdateParameters>
                <asp:Parameter Name="idPessoa" Type="Int32" />
                <asp:Parameter Name="senha" Type="String" />
                <asp:Parameter Name="perfil" Type="String" />
                <asp:Parameter Name="usuario" Type="String" />
            </UpdateParameters>
        </asp:SqlDataSource>
    </p>
    <p>
        &nbsp;</p>
    <p>
        &nbsp;</p>
    <p>
        &nbsp;</p>
    <p>
        &nbsp;</p>
    <p>
        Clínica Bem Estar<br />
        Rua Julio de Castilhos - Bairro Centro - Caxias do Sul - RS</p>
</asp:Content>

